Skip to content

[FEAT] Add dockerfile#4

Merged
martian56 merged 2 commits intomainfrom
add-dockerfile
Mar 14, 2026
Merged

[FEAT] Add dockerfile#4
martian56 merged 2 commits intomainfrom
add-dockerfile

Conversation

@martian56
Copy link
Copy Markdown
Member

This pull request introduces real-time remote cursor support to the collaborative board, improves WebSocket integration, and adds backend and frontend infrastructure for better development and testing. The most significant changes are the addition of remote cursor visualization, a new custom React hook for WebSocket board communication, and backend updates to support these features. It also adds Docker support and basic API tests.

Frontend: Real-time Collaboration Features

  • Added a RemoteCursorsOverlay React component to visually display other users' cursors on the board, showing their position and username. (apps/frontend/src/components/board/RemoteCursorsOverlay.tsx apps/frontend/src/components/board/RemoteCursorsOverlay.tsxR1-R69)
  • Implemented the useBoardWebSocket custom hook to manage WebSocket connections, handle incoming cursor and document update events, and maintain a list of remote user cursors. (apps/frontend/src/hooks/useBoardWebSocket.ts apps/frontend/src/hooks/useBoardWebSocket.tsR1-R123)
  • Integrated remote cursor sending and display into the BoardPage, wiring up pointer movement to broadcast the current user's cursor and rendering the overlay for remote cursors. (apps/frontend/src/pages/board/BoardPage.tsx [1] [2] [3]

Frontend: WebSocket Utilities

  • Added utility functions getWsBaseUrl and getBoardWsUrl to construct proper WebSocket URLs for board communication, supporting both HTTP and HTTPS environments. (apps/frontend/src/lib/api.ts apps/frontend/src/lib/api.tsR24-R38)

Backend: WebSocket and API Enhancements

  • Updated the backend WebSocket router to include user_id and username in cursor.moved events, enabling the frontend to identify and label remote cursors. (api/app/app/websocket/router.py api/app/app/websocket/router.pyL56-R61)

Development and Testing Infrastructure

  • Added a .dockerignore file and a new Dockerfile for the API, using Python 3.12 and uv for dependency management, to facilitate containerized development and deployment. (api/app/.dockerignore [1] api/app/Dockerfile [2]
  • Introduced basic API test infrastructure with pytest configuration, fixtures, and initial tests for authentication and health endpoints. (api/app/pyproject.toml [1] [2] api/app/tests/conftest.py [3] api/app/tests/test_api_auth.py [4] api/app/tests/test_health.py [5]

@martian56 martian56 added this to the Deadline milestone Mar 14, 2026
@martian56 martian56 self-assigned this Mar 14, 2026
@martian56 martian56 merged commit 20908e6 into main Mar 14, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant